From 022cf55cf1bfd7a8aa08f19a3734f36154050859 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Mon, 22 Feb 2010 18:42:50 +0000 Subject: [PATCH] hvmloader: Replace unportable usage of GNU head with portable awk. Signed-off-by: Keir Fraser --- tools/firmware/hvmloader/acpi/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/firmware/hvmloader/acpi/Makefile b/tools/firmware/hvmloader/acpi/Makefile index 7d82c63cbd..3fdb7c27e1 100644 --- a/tools/firmware/hvmloader/acpi/Makefile +++ b/tools/firmware/hvmloader/acpi/Makefile @@ -31,9 +31,10 @@ ssdt_pm.h ssdt_tpm.h: %.h: %.asl iasl sed -e 's/AmlCode/$*/g' $*.hex >$@ rm -f $*.hex $*.aml +# NB. awk invocation is a portable alternative to 'head -n -1' dsdt_15cpu.c dsdt_anycpu.c: %.c: dsdt.asl mk_dsdt.c iasl $(HOSTCC) $(HOSTCFLAGS) $(CFLAGS_include) -o mk_$* mk_dsdt.c - head -n -1 $< >$*.asl + awk 'NR > 1 {print s} {s=$$0}' $< >$*.asl ./mk_$* >>$*.asl iasl -p $* -tc $*.asl sed -e 's/AmlCode/$*/g' $*.hex >$@ -- 2.30.2